<include>
<context name="incall_{$gateway.username}">
<extension name="{$gateway.username}">
    <condition field="destination_number" expression="^(.*)$">
      <!--
	  If you're hosting multiple domains you will want to set the
	  target_domain on these calls so they hit the proper domain after you
	  transfer the caller into the default context. 
	  
	  $${domain} is the default domain set from vars.xml but you can set it
	  to any domain you have setup in your user directory.

      --> 
      <action application="set" data="gateway={$gateway.username}"/>
      <!--<action application="set" data="sip_h_X-Gateway=${gateway}"/>-->
      <action application="set" data="domain_name=$${domain}"/>
      <action application="set" data="caller_id_number=${caller_id_name}"/>
      <!-- This example maps the DID 5551212 to ring 1000 in the default context -->
      <action application="log" data="WARNING gongji2ttt-${caller_id_name},${caller_id_number}"/>
      <action application="transfer" data="{$extension.extension} XML incall"/>
    </condition>
  </extension>
</context>
</include>
